<template>
    <div>
        <div class="flex-box flex-ac flex-pj data-pd bor-b-g" v-for="(item, i) in dataList" :key="i" @click="openDetails(item)">
            <div class="icon-wd">
                <div class="iconSize-2" :class="item.ename"></div>
                <div class="tx-c mar-t-5 tx-s-12">{{ item.lotType }}</div>
            </div>
            <div class="flex-f1 mar-lr">
                <div class="flex-box flex-pj">
                    <div class="tx-s-14">投注号码：{{ item.playType }}</div>
                    <div class="tx-s-14">{{ item.ticketPrice }}元</div>
                </div>
                <div class="flex-box flex-pj mar-t">
                    <div class="tx-s-14 tx-c-666" :class="{
                        'tx-c-b' : item.status == '0',
                        'tx-c-r' : item.status == '1',
                        'tx-c-o' : item.status == '4'
                    }">{{ orderStatus[item.status] }}</div>
                    <div class="tx-s-12">{{ item.createTime }}</div>
                </div>
            </div>
            <div class="arrow_right"></div>
        </div>
    </div>
</template> 
<script type="text/ecmascript-6">
import "common/css/user.css";
export default {
    data() {
        return {
            orderStatus: ["待开奖", "已中奖", "未中奖", '', "未成功"]
        };
    },
    methods: {
        openDetails(data) {
            this.$router.push({
                path: "/myRecordDtails",
                query: {
                    id: data.ticketNo
                }
            });
        }
    },
    props: {
        dataList: Array
    }
};
</script>

<style scoped lang="stylus" rel="stylesheet/stylus"> 
    .data-pd 
        padding: 0.75rem
    .icon-wd
        width: 5rem
    .mar-lr
        margin: 0 0.75rem
    .mar-t
        margin-top: 2rem
    .yfsc
        background-image: url('../common/image/icon_jssc.png')
    .bflhc
        background-image: url('../common/image/icon_jslhc.png')
    .yfssc
        background-image: url('../common/image/icon_ffc.png')
    .bfefc
        background-image: url('../common/image/icon_efc.png')
    .bfwfc
        background-image: url('../common/image/icon_wfc.png')
    .xjssc
        background-image: url('../common/image/icon_xjssc.png')
    .cqssc
        background-image: url('../common/image/icon_ssc.png')
    .bjpk10
        background-image: url('../common/image/icon_bjsc.png')
    .xglhc
        background-image: url('../common/image/icon_lh.png')
</style>